/*********************************************************************
* File:: AgentAndWorldSampleAgent.h
* \brief The agent and world interfaces sample.
*********************************************************************/
#pragma once
#pragma warning (disable: 4482) // Ignore non-standard extension warnings

#include "../Agent.h"
using namespace agents;

namespace agents{ namespace samples{
	/**
	* \class AgentAndWorldSampleAgent
	* \brief The agent and world interfaces sample.
	*
	* The agents respond to the following team chat messages:
	* - \c timeLeftInRound or \c tR: Reports the time left in the round
	* - \c mapType or \c mT: Reports the map type
	* - \c isBombPlanted or \c iBP: Reports whether the bomb is planted
	* - \c toggleMonitorDamage or \c tMD: Toggles whether to report when took damage in the previous cycle
	* - \c health or \c h: Reports the agent's health
	* - \c id: Reports the agent's name and id
	*
	* \author Instituto Superior Tecnico de Lisboa, Portugal
	* \author Technical University of Lisbon, Portugal
	* 
	* \author Agentes Autonomos e Sistemas Multiagente
	* \author Autonomous Agents and Multiagent Systems
	* 
	* \version	1.0
	* \date		2006/2007
	**/
	class AgentAndWorldSampleAgent: public Agent{
	public:
		AgentAndWorldSampleAgent(edict_t *enity, int team, int model);
		~AgentAndWorldSampleAgent();

	private:
		void newRound();
		void think();
		void handleMessage(ICommunication::MessageRecord& record);

		bool _isMonitoringDamage;
	};
}}